import request from '@/utils/request'

// 商品类型管理接口
export const getList = (data) => request.get('/api/goodsType/page', {
  params: {
    id: data.id,
    like_name: data.like_name,
    like_code: data.like_code,
    size: data.size,
    current: data.current,
    descs: data.descs
  }
})

export const getCode = () => request.get('/api/codeFactory/next/HPLX')

export const add = (data) => request.post('/api/goodsType', data)

export const edit = (id) => request.get(`/api/goodsType/${id}`)

export const editSubmit = (data) => request.put('/api/goodsType', data)
